<ion-view hide-back-button="true" hide-nav-bar="true" cache-view="true">
    <ion-header-bar>
        <a class="button button-icon icon ion-navicon" ui-sref="sort"></a>
        <div class="h1 title home">
            <label class="item item-input item-input-wrapper">
                <i class="icon ion-search placeholder-icon"></i>
                <input type="text" ng-focus="searchStart()" ng-model="searchText">
            </label>
        </div>
        <button class="button button-clear button-positive icon ion-android-more-vertical" on-tap="popover.show($event)"></button>
    </ion-header-bar>
    <ion-content class="padding-horizontal">
        <ion-refresher on-refresh="doRefresh()" pulling-text="下拉刷新..." refreshing-text="刷新中!" refreshing-icon="ion-loading-c">
        </ion-refresher>
        <ion-list>
            <a class="item item-thumbnail-left" ng-repeat="product in items" on-tap="forwardSingle(product)" >
                <img ng-src="data:image/jpg;base64,{{product.Picture}}">
                <h2>{{product.ItemName}}</h2>
                <p class="price">￥{{product.Price}}</p>
            </a>
        </ion-list>
        <ion-infinite-scroll
                ng-if="infiniteable"
                on-infinite="loadMore()"
                distance="1%" immediate-check="true">
        </ion-infinite-scroll>
    </ion-content>
</ion-view>
